package com.bricker.laboratorymanagement.business.service;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.bricker.laboratorymanagement.business.entity.SysUser;
import com.bricker.laboratorymanagement.business.model.ResultLogin;
import com.bricker.laboratorymanagement.business.model.UserModel;
import com.bricker.laboratorymanagement.business.model.UserSelectModel;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;
import java.util.Map;

public interface SysUserService extends IService<SysUser> {

    /**
     * 用户登录
     * @param loginUser
     * @return
     */
    public ResultLogin login(SysUser loginUser);

    /***
     * 用户注册
     * @param registerUser
     * @return
     */
    public Map<String,Object> register( SysUser registerUser);


    /***
     * 用户修改
     * @param updateUser
     * @return
     */
    public Map<String,Object> updateUser(SysUser updateUser);


    /**
     * 分页多条件查询实验项目
     * @param userSelectModel
     * @return
     */
    public Page<UserModel> getUserByPage(UserSelectModel userSelectModel);
    /**
     * 获取当前用户信息
     */
    public UserModel  getCurrentUser( Long id);

    void saveOrUpdateUser(Long uId, List<SysUser> users);
}
